﻿<!--
    This file is part of "Information Connections Engine".

    "Information Connections Engine" is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation, either version 2 of the License, or
    (at your option) any later version.

    "Information Connections Engine" is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with "Information Connections Engine".  If not, see http://www.gnu.org/license.
-->
<UserControl x:Class="ICE.view.UserNavigationMenu"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" 
    xmlns:layoutToolkit="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Layout.Toolkit"
    xmlns:controls="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Toolkit"
    xmlns:system="clr-namespace:System;assembly=mscorlib"
    Width="220" xmlns:vsm="clr-namespace:System.Windows;assembly=System.Windows" >
    <Grid x:Name="LayoutRoot" HorizontalAlignment="Left" Width="15">
    	<Grid.ColumnDefinitions>
    		<ColumnDefinition Width="*"/>
    		<ColumnDefinition Width="15"/>
    	</Grid.ColumnDefinitions>
    	<vsm:VisualStateManager.VisualStateGroups>
    		<vsm:VisualStateGroup x:Name="OpenClose">
    			<vsm:VisualStateGroup.Transitions>
    				<vsm:VisualTransition GeneratedDuration="00:00:00.3000000"/>
    			</vsm:VisualStateGroup.Transitions>
    			<vsm:VisualState x:Name="open">
    				<Storyboard>
    					<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="LayoutRoot" Storyboard.TargetProperty="(FrameworkElement.Width)">
    						<SplineDoubleKeyFrame KeyTime="00:00:00" Value="220"/>
    					</DoubleAnimationUsingKeyFrames>
    					<PointAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="grid" Storyboard.TargetProperty="(UIElement.RenderTransformOrigin)">
    						<SplinePointKeyFrame KeyTime="00:00:00" Value="0.5,0.5"/>
    					</PointAnimationUsingKeyFrames>
    					<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="grid" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleX)">
    						<SplineDoubleKeyFrame KeyTime="00:00:00" Value="-1"/>
    					</DoubleAnimationUsingKeyFrames>
    				</Storyboard>
    			</vsm:VisualState>
    			<vsm:VisualState x:Name="close"/>
    		</vsm:VisualStateGroup>
    	</vsm:VisualStateManager.VisualStateGroups>
    	<Border x:Name="border" VerticalAlignment="Stretch" HorizontalAlignment="Stretch" Grid.ColumnSpan="4" BorderBrush="#FF141212" BorderThickness="0,0.5,0.5,0.5" CornerRadius="0,6,6,0" Opacity="0.8">
    		<Border.Background>
    			<LinearGradientBrush EndPoint="1,1.003" StartPoint="-0.012,0.013">
    				<GradientStop Color="AliceBlue" Offset="0.2"/>
    				<GradientStop Color="SkyBlue" Offset="1"/>
    			</LinearGradientBrush>
    		</Border.Background>
    	</Border>
    	<Grid Height="15" HorizontalAlignment="Center" VerticalAlignment="Center" Width="15" Grid.Column="1" Grid.ColumnSpan="1" x:Name="grid">
    		<Grid.RenderTransform>
    			<TransformGroup>
    				<ScaleTransform/>
    				<SkewTransform/>
    				<RotateTransform/>
    				<TranslateTransform/>
    			</TransformGroup>
    		</Grid.RenderTransform>
    		<Path Height="16.95" Margin="0,-10.8,-9.6,4.781" Width="16.95" RenderTransformOrigin="0.082906443336382,0.907564602397488" Fill="#FF3F72E2" Stretch="Fill" Data="M0,4.9497509 L2.9962544,4.9497509 L2.9962544,13.999172 L12,13.999172 L12,16.949751 L0.014981247,16.949751 L0.014981247,16.752064 L0,16.752064 z M4.9497504,0 L7.9460044,0 L7.9460044,9.0494213 L16.949749,9.0494213 L16.949749,11.999999 L4.9647317,11.999999 L4.9647317,11.802311 L4.9497504,11.802311 z" HorizontalAlignment="Right">
    			<Path.RenderTransform>
    				<TransformGroup>
    					<ScaleTransform ScaleX="-0.40000000596046448" ScaleY="0.40000000596046448"/>
    					<SkewTransform/>
    					<RotateTransform Angle="-45"/>
    					<TranslateTransform/>
    				</TransformGroup>
    			</Path.RenderTransform>
    		</Path>
    	</Grid>
    	<Button Content="Button" Opacity="0" Cursor="Hand" ToolTipService.ToolTip="Open" Click="Button_Click" Grid.Column="1"/>
        <layoutToolkit:Accordion x:Name="menu" VerticalAlignment="Stretch" HorizontalAlignment="Stretch" SelectionMode="One" Margin="1,1,1,1" BorderThickness="0">
            <layoutToolkit:AccordionItem Background="#6FFFFFFF" BorderThickness="0">
                <layoutToolkit:AccordionItem.Header>
                    <TextBlock Text="Show/Hide Nodes" Foreground="DarkBlue"/>
                </layoutToolkit:AccordionItem.Header>
                <layoutToolkit:AccordionItem.Content>
                    <StackPanel x:Name="ShowHideNodeStackPanel" Width="200"/>
                </layoutToolkit:AccordionItem.Content>
            </layoutToolkit:AccordionItem>
            <layoutToolkit:AccordionItem Background="#6FFFFFFF" BorderThickness="0" >
                <layoutToolkit:AccordionItem.Header>
                    <TextBlock Text="Show/Hide Links" Foreground="DarkGreen"/>
                </layoutToolkit:AccordionItem.Header>
                <layoutToolkit:AccordionItem.Content>
                    <StackPanel x:Name="ShowHideLinkStackPanel" Width="200"/>
                </layoutToolkit:AccordionItem.Content>
            </layoutToolkit:AccordionItem>
            <layoutToolkit:AccordionItem x:Name="accordeonGroupMenu" Background="#6FFFFFFF" BorderThickness="0">
                <layoutToolkit:AccordionItem.Header>
                    <TextBlock Text="Group Action" Foreground="DarkRed"/>
                </layoutToolkit:AccordionItem.Header>
                <layoutToolkit:AccordionItem.Content>
                    <Grid Width="200" Height="320">
                        <Grid.RowDefinitions>
                            <RowDefinition Height="30*"/>
                            <RowDefinition Height="200*"/>
                            <RowDefinition Height="70*"/>
                        </Grid.RowDefinitions>
                        <Grid>
                            <TextBlock Text="Drop one or more nodes here" TextWrapping="Wrap" HorizontalAlignment="Center" VerticalAlignment="Center"/>
                        </Grid>
                        <Grid Grid.Row="2" >
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="0.705*"/>
                                <ColumnDefinition Width="0.295*"/>
                            </Grid.ColumnDefinitions>
                            <Button Margin="4,4,4,4" Content="Clear" Grid.Column="1" Click="ClearGroupList"/>
                            <ScrollViewer Grid.ColumnSpan="1" VerticalScrollBarVisibility="Auto" BorderBrush="{x:Null}">
                                <controls:WrapPanel x:Name="ActionListPanel"/>
                            </ScrollViewer>
                        </Grid>
                        <ScrollViewer Grid.RowSpan="1" Grid.Row="1" Padding="0,0,0,0" VerticalScrollBarVisibility="Auto" BorderBrush="{x:Null}">
                            <StackPanel x:Name="nodeListPanel"/>
                        </ScrollViewer>
                    </Grid>
                </layoutToolkit:AccordionItem.Content>
            </layoutToolkit:AccordionItem>
        </layoutToolkit:Accordion>
    </Grid>
</UserControl>
